package tests;

import server.Server;
import client.*;
import dictionary.interfaceData.GameState;
import dictionary.interfaceData.Player;

public class ClientTest {

	public static void main(String[] args) {
		
		ClientTest tester = new ClientTest();
		tester.test();
	}
	public void test() {
		final AppWindow gui;
		
		gui = new AppWindow();
		
		new Thread("tester")
		{
			public void run() 
			{
				Server server = new Server(true);
				try {
					Thread.sleep(500L);
				} catch (InterruptedException e) {
					// TODO Auto-generated catch block
					e.printStackTrace();
				}
				GameState state = server.testerGetUpdate().gameState;
				Player thisPlayer = server.allPlayers.get(0);
				System.out.println(thisPlayer);
				System.out.println(state);
				gui.updateGUIState(server.testerGetUpdate().gameState, 
						server.testerGetUpdate().statusLogEntries.get(thisPlayer ), 
						server.testerGetUpdate().suggestionOrAccusation);
			};
		};
	}
	
}
